Repository navigation
Conversation
check -p --references passed a Hidden attribute of a Protected (add-on) module read on the result of `call microflow`, which mxbuild refuses with CE1406; a CHANGE on a call result with an unknown attribute missed its CE1613 report the same way. walkTypedFlow, the variable-typing walk both member checks share, typed parameters, create, retrieve and loop iterators but not a call's output variable, so a member path on it resolved no entity. The output now holds the stored callee's return entity (object or list, which also types a loop over it). A callee the script itself creates or rewrites stays untyped: its stored return type may be the one being replaced, and a stale type would be a false refusal. Closes mendixlabs#1654 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1654
What does it do?
check -p --referencesnow knows which entity the output variable ofcall microflowholds, so amember read on a call result is checked like one on a parameter:
now gives
CE1406: declare $Secret is not allowed to use attribute 'AddOn.Request.Secret' …. Before thischange it passed
checkandexec, and mxbuild refused it with CE1406. The same gap leftchange $r (NoSuchAttribute = …)on a call result without its CE1613 report.Root cause:
walkTypedFlow(mdl/executor/validate_member_refs.go), the one variable-typing walkthe
--referencesmember checks share, typed parameters,create,retrieveand loop iterators, butnot the output of
call microflow. A member path on an untyped variable resolves no entity, so everycheck on it stayed silent.
Change:
walkTypedFlowtypes a call's output from the stored callee's return type (ObjectTypeorListType, which carry the entity's qualified name); a list return also types a loop over it. A calleethe same script creates or rewrites is left untyped: its stored return type may be the one the script
replaces, and a stale type would turn a valid member into a false refusal. Both callers pass that set
(
scriptContext.microflowsfor the member check, the resolver'sscriptFlowsfor the Protected-modulecheck). New helper
storedMicroflowReturnEntity. Small and focused: one walk and its two callers.Files
mdl/executor/validate_member_refs.go: call output typing inwalkTypedFlow,storedMicroflowReturnEntitymdl/executor/validate_protected_module_members.go: passes the script's flows to the walkmdl/executor/validate_member_refs_test.go:TestValidateMemberReferences_TypesACallMicroflowResultmdl/executor/validate_protected_module_refs_test.go: a UsableAPI_GetPubin the fixture, three casesCHANGELOG.md: entry under Unreleased / Fixed.claude/skills/fix-issue/findings/mdl-executor/2026-10-25-call-microflow-output-untyped-member-checks-silent.jsonTesting
TestValidateMemberReferences_TypesACallMicroflowResult: achangewith an unknown attribute on anobject call result and on the iterator over a list call result is reported; a real attribute is not;
a callee the script rewrites stays untyped (no report).
TestValidateProtectedModuleRefs: a Hidden attribute on a call result in areturnand in adeclareis CE1406; a Usable attribute on it is clean.(
got []); with the fix they pass.make build,make testandmake lint(lint-go, lint-ts, check-conformance,check-test-timeouts) pass;
make check-findingspasses. (On macOS,cmd/mxcli/docker'sTestSyncJavaDependencies_*need asetsidon PATH, onmainas here; unrelated.)The issue's script was measured with
mx checkon Mendix 11.12.4 (CE1406 on the declare) and withcheckontestdata/testapp(11.14.0).Checklist
check -p --referencesdoes not type acall microflowresult, so a Hidden attribute of a Protected module read on it passes (CE1406) #1654 (split fromcheck -p --referencesmisses CE1406 for a database retrieve or a create of a Hidden entity of a Protected module #1652, which has its own PR)mainmake check-findingspasses🤖 Generated with Claude Code